var acctg_admin = {
	save_db_config:function(id,msg_id){
		var db = $(id).val();
		if(db == ""){
			alert("db cannot be empty");
		} else {
			var url = Drupal.settings.basePath+"accounting/admin/db/save";
			$.ajax({
				data:{"db":db},
				dataType:"json",
				error:function(r,t,e){alert(t);},
				success:function(d,t){
					if(d.return_value){
						alert("saved");
					} else {
						alert(d.error);
					}
				},
				type:"POST",
				url:url
			});
		}
	}
}